<?php
require_once("lib.php");

$path=isset($_GET['path']) ? $_GET['path'] : '/';
$list=listdir($path);
echo json_encode($list);
$l=ob_get_length();
header("Content-Length: ".$l);

?>
